#include once "object.bi"
using ext

#define odefine fbext_TDefine( fbext_Array, public, ((object)) )
odefine

constructor object()
	weight = 255
	value = 0
end constructor

constructor object( byref rhs as const object )

	name = rhs.name
	sdesc = rhs.sdesc
	ldesc = rhs.ldesc
	weight = rhs.weight
	value = rhs.value
	
	pixmap = new gfx.Sprite( *(rhs.pixmap) )
	
end constructor

operator object.Let( byref rhs as const object )

	name = rhs.name
	sdesc = rhs.sdesc
	ldesc = rhs.ldesc
	weight = rhs.weight
	value = rhs.value
	
	pixmap = new gfx.Sprite( *(rhs.pixmap) )

end operator

constructor object( byref _name as string, byref _sdesc as string="", byref _ldesc as string ="", byval _weight as ubyte=255, byval _value as uinteger = 0 )

	name = _name
	sdesc = _sdesc
	ldesc = _ldesc
	weight = _weight
	value = _value
	
end constructor

destructor object()

	name = ""
	sdesc = ""
	ldesc = ""
	
	if pixmap <> null then delete pixmap

end destructor


